/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * tela_erro.java
 *
 * Created on 10/10/2011, 18:30:40
 */
package extras;

/**
 *
 * @author Diego
 */
public class tela_erro extends javax.swing.JFrame
{

    /** Creates new form tela_erro */
    public tela_erro(String erro)
    {
        initComponents();
        setVisible(true);
        setLocationRelativeTo(null);
        erro_log.setText(erro);
    }

    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        jLabel1 = new javax.swing.JLabel();
        jScrollPane1 = new javax.swing.JScrollPane();
        erro_log = new javax.swing.JTextArea();

        setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
        setTitle("SGH :: Ocorreu um erro");
        setAlwaysOnTop(true);
        setResizable(false);

        jLabel1.setText("Ocorreu um erro em nosso sistema. Verifique o LOG abaixo:");

        erro_log.setColumns(20);
        erro_log.setEditable(false);
        erro_log.setLineWrap(true);
        erro_log.setRows(5);
        erro_log.setCursor(new java.awt.Cursor(java.awt.Cursor.DEFAULT_CURSOR));
        jScrollPane1.setViewportView(erro_log);

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 717, Short.MAX_VALUE)
                    .addComponent(jLabel1))
                .addContainerGap())
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jLabel1)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 149, Short.MAX_VALUE)
                .addContainerGap())
        );

        pack();
    }// </editor-fold>//GEN-END:initComponents

    /**
     * @param args the command line arguments
     */
    
   
    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JTextArea erro_log;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JScrollPane jScrollPane1;
    // End of variables declaration//GEN-END:variables
}
